<?php
class Course {
    private $courseCode;
    private $courseName;
    private $credits;
    
    public function __construct($courseCode, $courseName, $credits) {
        $this->courseCode = $courseCode;
        $this->courseName = $courseName;
        $this->credits = $credits;
    }
    
    public function getCourseCode() {
        return $this->courseCode;
    }
    
    public function getCourseName() {
        return $this->courseName;
    }
    
    public function getCredits() {
        return $this->credits;
    }
    
    public function toString() {
        return $this->courseCode . " - " . $this->courseName . " (" . $this->credits . " credits)";
    }
}
?>
    
